\frame[containsverbatim]
{
  \frametitle{LockCount class}
{\scriptsize
\begin{verbatim}
public class LockCount {
  public static final int TOP = -1;
  public static final int BOTTOM = -2;

  private int count;

  public LockCount(int count) { this.count = count; }

  public boolean isTop() { return count == TOP; }
  public boolean isBottom() { return count == BOTTOM; }

  public void setCount(int count) { this.count = count; }

  public int getCount() { return count; }

  @Override
  public String toString() { return String.valueOf(count); }
}
\end{verbatim}
}
}
